Public Class FastForeward
    Private bbb As Integer = 0
    Public Property a() As Integer
        Get
            Return bbb
        End Get
        Set(ByVal value As Integer)
            bbb = value
            DrawPlain()
        End Set
    End Property
    Private Sub FastForeward_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        DrawPlain()
    End Sub
    Public Sub DrawPlain()
        Dim bmp As New Bitmap(Me.Width, Me.Height)
        Dim g As Graphics = Graphics.FromImage(bmp)
        Dim path As New Drawing2D.GraphicsPath


        path.AddArc(New Rectangle(0, 0, 10, 10), 180, 90)
        path.AddLine(5, 0, 15, 0)
        path.AddArc(New Rectangle(9, 0, 10, 10), 270, 90)
        path.AddLine(20, 5, 20, 15)
        path.AddArc(New Rectangle(9, 9, 10, 10), 0, 90)
        path.AddLine(15, 20, 5, 20)
        path.AddArc(New Rectangle(0, 9, 10, 10), 90, 90)
        path.AddLine(0, 15, 0, 5)
        Dim b1 As New Drawing2D.PathGradientBrush(path)
        b1.CenterColor = Color.Green
        b1.CenterPoint = New PointF(10, 10)
        b1.SurroundColors = New Color() {Color.LightGreen}
        g.FillRectangle(b1, New Rectangle(0, 0, 20, 20))
        g.FillPolygon(Brushes.Snow, New PointF() {New PointF(5, 5), New PointF(5, 15), New PointF(15, 10)})

        Me.BackgroundImage = bmp
    End Sub
    Public Sub DrawHover()
        Dim bmp As New Bitmap(Me.Width, Me.Height)
        Dim g As Graphics = Graphics.FromImage(bmp)
        Dim path As New Drawing2D.GraphicsPath


        path.AddArc(New Rectangle(0, 0, 10, 10), 180, 90)
        path.AddLine(5, 0, 15, 0)
        path.AddArc(New Rectangle(9, 0, 10, 10), 270, 90)
        path.AddLine(20, 5, 20, 15)
        path.AddArc(New Rectangle(9, 9, 10, 10), 0, 90)
        path.AddLine(15, 20, 5, 20)
        path.AddArc(New Rectangle(0, 9, 10, 10), 90, 90)
        path.AddLine(0, 15, 0, 5)
        Dim b1 As New Drawing2D.PathGradientBrush(path)
        b1.CenterColor = Color.LightGreen
        b1.CenterPoint = New PointF(11, 9)
        b1.SurroundColors = New Color() {Color.DarkGreen}
        g.FillRectangle(b1, New Rectangle(0, 0, 20, 20))
        g.FillPolygon(Brushes.Snow, New PointF() {New PointF(6, 4), New PointF(6, 14), New PointF(16, 9)})

        Me.BackgroundImage = bmp
    End Sub
    Public Sub DrawClicked()
        Dim bmp As New Bitmap(Me.Width, Me.Height)
        Dim g As Graphics = Graphics.FromImage(bmp)
        Dim path As New Drawing2D.GraphicsPath


        path.AddArc(New Rectangle(0, 0, 10, 10), 180, 90)
        path.AddLine(5, 0, 15, 0)
        path.AddArc(New Rectangle(9, 0, 10, 10), 270, 90)
        path.AddLine(20, 5, 20, 15)
        path.AddArc(New Rectangle(9, 9, 10, 10), 0, 90)
        path.AddLine(15, 20, 5, 20)
        path.AddArc(New Rectangle(0, 9, 10, 10), 90, 90)
        path.AddLine(0, 15, 0, 5)
        Dim b1 As New Drawing2D.PathGradientBrush(path)
        b1.CenterColor = Color.DarkGreen
        b1.CenterPoint = New PointF(8, 13)
        b1.SurroundColors = New Color() {Color.MediumSpringGreen}
        g.FillRectangle(b1, New Rectangle(0, 0, 20, 20))
        g.FillPolygon(Brushes.Snow, New PointF() {New PointF(4, 6), New PointF(4, 16), New PointF(14, 11)})

        Me.BackgroundImage = bmp
    End Sub

    Private Sub FastForeward_MouseDown(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles Me.MouseDown
        DrawClicked()
    End Sub


    Private Sub FastForeward_MouseEnter(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.MouseEnter
        DrawHover()
    End Sub

    Private Sub FastForeward_MouseLeave(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.MouseLeave
        DrawPlain()
    End Sub

    Private Sub FastForeward_MouseUp(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles Me.MouseUp
        DrawHover()
    End Sub
End Class
